package com.ruoyi.transfer_log.domain;

import java.math.BigDecimal;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 交易日志对象 sys_transfer_log
 * 
 * @author 张富饶
 * @date 2025-05-21
 */
public class TransferLog extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    private Long id;

    /** 操作类型（0-转账 1-商品交易） */
    @Excel(name = "操作类型", readConverterExp = "0=-转账,1=-商品交易")
    private Integer operateType;

    /** 发起方用户ID */
    @Excel(name = "发起方用户ID")
    private Long fromUserId;

    /** 接收方用户ID */
    @Excel(name = "接收方用户ID")
    private Long toUserId;

    /** 交易金额 */
    @Excel(name = "交易金额")
    private BigDecimal amount;

    /** 关联订单ID */
    @Excel(name = "关联订单ID")
    private Long orderId;

    /** 交易描述 */
    @Excel(name = "交易描述")
    private String description;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }

    public void setOperateType(Integer operateType) 
    {
        this.operateType = operateType;
    }

    public Integer getOperateType() 
    {
        return operateType;
    }

    public void setFromUserId(Long fromUserId) 
    {
        this.fromUserId = fromUserId;
    }

    public Long getFromUserId() 
    {
        return fromUserId;
    }

    public void setToUserId(Long toUserId) 
    {
        this.toUserId = toUserId;
    }

    public Long getToUserId() 
    {
        return toUserId;
    }

    public void setAmount(BigDecimal amount) 
    {
        this.amount = amount;
    }

    public BigDecimal getAmount() 
    {
        return amount;
    }

    public void setOrderId(Long orderId) 
    {
        this.orderId = orderId;
    }

    public Long getOrderId() 
    {
        return orderId;
    }

    public void setDescription(String description) 
    {
        this.description = description;
    }

    public String getDescription() 
    {
        return description;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("operateType", getOperateType())
            .append("fromUserId", getFromUserId())
            .append("toUserId", getToUserId())
            .append("amount", getAmount())
            .append("orderId", getOrderId())
            .append("description", getDescription())
            .append("createTime", getCreateTime())
            .toString();
    }
}
